package by.vkhalko.asamo.dataaccess.impl;

import java.util.List;

import org.springframework.stereotype.Repository;

import by.vkhalko.asamo.dataaccess.PersonDao;
import by.vkhalko.asamo.datamodel.Company;
import by.vkhalko.asamo.datamodel.Person;
import by.vkhalko.asamo.datamodel.Person_;

@Repository
public class PersonDaoImpl extends AbstractDaoImpl<Long, Person> implements
		PersonDao {

	protected PersonDaoImpl() {
		super(Person.class);
	}

	@Override
	public List<Person> getAllByCompany(Company company) {
		return getAllByFieldRestriction(Person_.company, company);
	}
}
